package main

import (
	"Todolist/config"
	"Todolist/pkg/utils"
	"Todolist/repository/cache"
	"Todolist/repository/db/dao"
	"Todolist/router"
	"fmt"
)

func main() {
	loading()
	config.InitConfig()
	r := router.NewRouter()
	fmt.Print("启动成功...")

	_ = r.Run(config.Config.System.HttpPort)
}

func loading() {
	config.InitConfig()
	dao.MySQLInit()
	utils.InitLog()
	cache.RedisInit()
}
